#ifndef SM2_RAND_H
#define SM2_RAND_H

#include <sm2_sign.h>
#include <string.h>
#include "sm2_operation.h"
#include "sm2_ec.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>

int sm2_rand(sm2_uint256_t k, const sm2_uint256_t low, const sm2_uint256_t high);
int rand_bytes(uint8_t *buf, size_t len);
int sm2_rand_range(sm2_uint256_t r, const sm2_uint256_t range);
int sm2_key_generate(SM2_Key *key);
int sm2_key_print(FILE *fp, int fmt, int ind, const char *label, const SM2_Key *key);

#endif
